/**
 * 
 */
package com.swim.affiche.entity;

import org.hibernate.validator.constraints.NotBlank;
import org.hibernate.validator.constraints.Length;

import com.jeesite.common.entity.DataEntity;
import com.jeesite.common.mybatis.annotation.Column;
import com.jeesite.common.mybatis.annotation.Table;
import com.jeesite.common.mybatis.mapper.query.QueryType;

/**
 * 公告Entity
 * @author 刘军武
 * @version 2021-06-02
 */
@Table(name="t_affiche", alias="a", columns={
		@Column(name="id", attrName="id", label="唯一标识", isPK=true),
		@Column(name="content", attrName="content", label="公告内容"),
		@Column(includeEntity=DataEntity.class),
	}, orderBy="a.update_date DESC"
)
public class Affiche extends DataEntity<Affiche> {
	
	private static final long serialVersionUID = 1L;
	private String content;		// 公告内容
	
	public Affiche() {
		this(null);
	}

	public Affiche(String id){
		super(id);
	}
	
	@NotBlank(message="公告内容不能为空")
	@Length(min=0, max=500, message="公告内容长度不能超过 500 个字符")
	public String getContent() {
		return content;
	}

	public void setContent(String content) {
		this.content = content;
	}
	
}